from selenium.webdriver.common.by import By
from selenium.webdriver.remote.webdriver import WebDriver

from src.day36.practice.member_page import Memberpage


class Mainpages:
    __CLINCK_TO_ADD_MEMBER=(By.CSS_SELECTOR,".ww_indexImg.ww_indexImg_AddMember")
    def __init__(self,driver:WebDriver):
        self.driver=driver

    def goto_memberpage(self):
        """
        跳转添加成员页面
        :return:
        """
        self.driver.find_element(*self.__CLINCK_TO_ADD_MEMBER).click()
        return Memberpage(self.driver)